<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ page contentType="text/html; charset=utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'regmsg.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<%
		String msg = (String) session.getAttribute("msg");
		session.setAttribute("msg","");
	%>
	<script type="text/javascript" >
		window.alert("<%=msg%>");
		<%System.out.println(msg);%>
		<%	if(msg.equals("取消成功！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("取消失败！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("已完成订单！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("操作失败！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("修改成功！")){%>
				window.location.href="<%=basePath%>admin/index.jsp";
			<%}%>
		<%	if(msg.equals("修改优惠卷成功！")){%>
				window.location.href="<%=basePath%>admin/creditex.jsp";
			<%}%>
		<%	if(msg.equals("修改失败！")){%>
				window.location.href="<%=basePath%>admin/index.jsp";
			<%}%>
		<%	if(msg.equals("修改管理员成功！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("修改管理员失败！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("添加管理员成功！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("添加管理员失败！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("删除管理员成功！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("删除管理员失败！")){%>
				window.location.href="<%=basePath%>admin/admin.jsp";
			<%}%>
		<%	if(msg.equals("修改订单成功！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("修改订单失败！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("已完成订单！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("操作失败！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("已退款！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("删除订单成功！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("删除订单失败！")){%>
				window.location.href="<%=basePath%>admin/order.jsp";
			<%}%>
		<%	if(msg.equals("修改类型成功！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("修改类型失败！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("删除类型成功！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("删除类型失败！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("删除用户成功！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("删除用户失败！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("删除配送员成功！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("删除配送员失败！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("添加类型成功！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("添加类型失败！")){%>
				window.location.href="<%=basePath%>admin/type.jsp";
			<%}%>
		<%	if(msg.equals("修改用户信息成功！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("修改用户信息失败！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("修改失败！账号已被使用,请重新修改")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("修改配送员信息成功！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("修改配送员信息失败！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("修改失败！配送员账号已被使用,请重新修改。")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("审核通过！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("审核失败！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("添加用户成功！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("添加用户失败！")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("添加失败！账号已被使用,请重新添加")){%>
				window.location.href="<%=basePath%>admin/user.jsp";
			<%}%>
		<%	if(msg.equals("添加配送员成功！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("添加配送员失败！")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("添加失败！配送员账号已被使用,请重新添加")){%>
				window.location.href="<%=basePath%>admin/clerk.jsp";
			<%}%>
		<%	if(msg.equals("添加成功！")){%>
				window.location.href="<%=basePath%>admin/creditex.jsp";
			<%}%>
		<%	if(msg.equals("下架失败！")){%>
				window.location.href="<%=basePath%>admin/creditex.jsp";
			<%}%>
		<%	if(msg.equals("下架成功！")){%>
				window.location.href="<%=basePath%>admin/creditex.jsp";
			<%}%>
	</script>
  </head>
  
  <body>
  </body>
</html>
